import { IForm } from '@/base-ui/form'
export const modelConfig: IForm = {
  formItems: [
    {
      field: 'name',
      type: 'input',
      lable: '菜单名称',
      placeholder: '请输入菜单名称',
      rules: [
        {
          required: true,
          message: '菜单名称不能为空',
          trigger: 'blur'
        }
      ]
    },
    {
      field: 'type',
      type: 'select',
      lable: '菜单类型',
      placeholder: '请选择菜单类型',
      options: [
        { title: '一级菜单', value: 1, id: '01' },
        { title: '二级菜单', value: 2, id: '02' },
        { title: '三级菜单', value: 3, id: '03' }
      ],
      rules: [
        {
          required: true,
          message: '菜单类型不能为空',
          trigger: 'blur'
        }
      ]
    },
    {
      field: 'parentId',
      type: 'select',
      lable: '上级菜单',
      placeholder: '请选择上级菜单',
      options: [],
      isHidden: false,
      rules: [
        {
          required: true,
          message: '上级菜单不能为空',
          trigger: 'blur'
        }
      ]
    },
    {
      field: 'url',
      type: 'input',
      lable: '菜单url',
      placeholder: '请输入菜单url',
      rules: [
        {
          required: true,
          message: '菜单url不能为空',
          trigger: 'blur'
        }
      ]
    },
    {
      field: 'icon',
      type: 'input',
      lable: '菜单图标',
      placeholder: '请输入菜单图标'
    },
    {
      field: 'permission',
      type: 'input',
      lable: '按钮权限',
      placeholder: '请输入按钮权限',
      isHidden: false
    }
  ],
  labelWidth: '100px',
  itemStyle: {
    padding: '10px 0px'
  },
  colLayout: {
    span: 24
  },
  title: '菜单'
}
